<%@ taglib uri="http://java.sun.com/jsf/html" prefix="h"%>
<%@ taglib uri="http://java.sun.com/jsf/core" prefix="f"%>
<%@ taglib uri="http://myfaces.apache.org/tomahawk" prefix="t"%>
<%@ taglib uri="http://richfaces.org/a4j" prefix="a4j"%>
<%@ taglib uri="http://richfaces.org/rich" prefix="rich"%>
<%@ taglib uri="http://jakarta.apache.org/struts/tags-tiles"
	prefix="tiles"%>
	
<rich:panel header="#{messages['voucher.mgmt.label']}">
	<h:panelGrid>
		<h:outputText value="#{errorBean.errorMessage}" styleClass="error"></h:outputText>
	</h:panelGrid>
	
	<h:panelGrid width="100%">
	    <h:outputText value="#{messages['voucher.list.rpt.label']}" styleClass="sub_header" />
	</h:panelGrid>
	
	
	
	<t:panelGrid columns="2" columnClasses="standardTable_ColumnLeft_20,standardTable_ColumnLeft_80" width="100%">
		<h:outputLabel for="voucherNo" value="#{messages['voucher.no.label']}" styleClass="standardText_Label" />
		<t:inputText id="voucherNo"  size="20" maxlength="20" styleClass="standardText" value="#{voucherMgmtBean.voucherNo}"></t:inputText>
		
		<h:outputLabel for="effectiveDate" value="#{messages['effective.date.label']}" styleClass="standardText_Label" />
		<h:panelGroup>
		    	<t:inputCalendar
		    	id="effectiveDate"
					monthYearRowClass="yearMonthHeader" weekRowClass="weekHeader" 
					currentDayCellClass="currentDayCell" value="#{voucherMgmtBean.effectiveDate}"
					renderAsPopup="true" popupTodayString="#{messages['popup.today']}"
					popupWeekString="#{messages['popup.week']}" popupDateFormat="dd/MM/yyyy"
					renderPopupButtonAsImage="true"
					styleClass="standardText" required="false"
		    	>
		    	</t:inputCalendar>
		</h:panelGroup>
		
		<h:outputLabel for="expiryDate" value="#{messages['expiry.date.label']}" styleClass="standardText_Label" />
		<h:panelGroup>
		    	<t:inputCalendar
		    	id="expiryDate"
					monthYearRowClass="yearMonthHeader" weekRowClass="weekHeader" 
					currentDayCellClass="currentDayCell" value="#{voucherMgmtBean.expiryDate}"
					renderAsPopup="true" popupTodayString="#{messages['popup.today']}"
					popupWeekString="#{messages['popup.week']}" popupDateFormat="dd/MM/yyyy"
					renderPopupButtonAsImage="true"
					styleClass="standardText" required="false"
		    	>
		    	</t:inputCalendar>
		</h:panelGroup>
	</t:panelGrid>
	
	<rich:spacer height="10"></rich:spacer>
	
	<t:panelGrid columns="2" columnClasses="standardTable_ColumnLeft_20,standardTable_ColumnLeft_80" width="100%">
	    <h:outputText></h:outputText>
		<h:commandButton value="#{messages['generate']}" styleClass="button" action="#{voucherMgmtBean.generateVoucherListReportAction}" ></h:commandButton>
	</t:panelGrid>
</rich:panel>	